<!DOCTYPE html>
<html lang="zh" xmlns:th="http://www.thymeleaf.org" xmlns:shiro="http://www.pollix.at/thymeleaf/shiro">
<head>
    <th:block th:include="include :: header('全部项目')" />
</head>
<body class="gray-bg">
     <div class="container-div">
        <div class="row">
            <div class="col-sm-12 search-collapse">
                <form id="formId">
                    <div class="select-list">
                        <ul>
                            <!-- <li>
                                <p>文件名：</p>
                                <input type="text" name="accename"/>
                            </li>
                            <li>
                                <p>上传人：</p>
                                <input type="text" name="operator"/>
                            </li> -->
                            <!-- <li>
                                <a class="btn btn-primary btn-rounded btn-sm" onclick="$.table.search()"><i class="fa fa-search"></i>&nbsp;搜索</a>
                                <a class="btn btn-warning btn-rounded btn-sm" onclick="$.form.reset()"><i class="fa fa-refresh"></i>&nbsp;重置</a>
                            </li> --> 
                        </ul>
                    </div>
                </form>
            </div>
            <div class="col-sm-12 select-table table-striped">
                 <table id="bootstrap-table"></table>
            </div>
        </div>
    </div>
    <th:block th:include="include :: footer" />
    <script th:inline="javascript">
    var prefix = ctx + "supervise/completionRecordRecord";
    
    $(function() {
    	var options = {
    			showSearch:false,
               	showRefresh:false,
               	showToggle:false,
               	showColumns:false,
    			url: prefix + "/list",
                detailUrl: prefix + "/detail/{id}",
                modalName: "施工许可",
                columns: [ {
					    field : 'guid', 
					    title : '序号',
					    visible: false
					},
					{
					    field: 'id',
					    title: '序号',
					    formatter: function (value, row, index) {
					
					        return index + 1;
					    }
					}, {
                        field: 'unitengineeringname',
                        title: '工程名称',
                        formatter: function (value, row, index) {
                            var actions = [];
                            actions.push('<a href="'+prefix+'/detail?guid='+row.guid+'">'+value+'</a>'); 
                            //actions.push('<a href="javascript:void(0)" onclick="$.operate.detailFull(\'' + row.id + '\')">'+value+'</a>');
                            return actions.join('');
                        }
                    }, 
                    {
                        field: 'cityAndCounty',
                        title: '市县',
						formatter: function (value, row, index) {
							value = '海口市';
						    return value;
						}
                    },
                    {
                        field: 'constructunit',
                        title: '建设单位'
                    },
                    {
                        field: 'totalcompany',
                        title: '施工单位'
                    },
                    {
                        field: 'time',
                        title: '上报日期'
                    },
                    {
	                    field: 'state',
	                    title: '状态'
	                },
                    {
	                    field: 'opera',
	                    title: '操作',
                        formatter: function (value, row, index) {
                            var actions = [];
                            actions.push('<a href="'+prefix+'/detail?guid='+row.guid+'">审查日志</a>'); 
                            //actions.push('<a href="javascript:void(0)" onclick="$.operate.detailFull(\'' + row.id + '\')">'+value+'</a>');
                            return actions.join('');
	                       }
	                }
                ]
    	    }
    	$.table.init(options);
    });
    </script>
</body>
</html>